package com.csdj.controller.sy;

import com.csdj.common.enums.AppHttpCodeEnum;
import com.csdj.common.utils.ResponseResult;
import com.csdj.pojo.SyEmp;
import com.csdj.service.SyEmpService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestParam;
import org.springframework.web.bind.annotation.RestController;

import java.util.List;

/**
 * @author 涵哥
 * @date 2023-08-24 14:19
 */
@RestController
@RequestMapping("/sy/emp")
public class SystemEmpController {

    @Autowired
    private SyEmpService syEmpService;

    @GetMapping("/getListByDeptId")
    public ResponseResult getListByDeptId(@RequestParam int id){
        List<SyEmp> list = syEmpService.getListByDeptId(id);
        return  ResponseResult.okResult(list);

    }
}
